- 
                Notifications
    You must be signed in to change notification settings 
- Fork 32
Add Swift SDK for Android to swift_package_test workflow #172
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add Swift SDK for Android to swift_package_test workflow #172
Conversation
| This PR will be ready to go once we have a new nightly Android SDK and some endpoint (like https://www.swift.org/api/v1/install/dev/main/android-sdk.json) to query the availability of the latest SDK. @shahmishal ping me once these are in place and I can cleanup the FIXMEs and move the PR out of draft status. | 
| 
 This should be resolved now. swiftlang/swift-org-website#1196 | 
| 
 It works! The last remaining FIXMEs are around the planned trimming of the "-0.1" from the download artifact name. I assume we need to wait for the next successful nightly build for that? | 
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM, after we fix FIXME:
 # FIXME: restore to main when this PR is ready to be merged
| 
 We can fix this in a future PR. | 
| OK, this is ready to go. Android tests in  If we need to iterate further, we can revert to using the PR's version at  | 
| Failures are expected because  | 
Enable the Android CI workflow added in swiftlang/github-workflows#172.
Enable the Android CI workflow added in swiftlang/github-workflows#172. ### Checklist: - [x] Code and documentation should follow the style of the [Style Guide](https://github.com/apple/swift-testing/blob/main/Documentation/StyleGuide.md). - [x] If public symbols are renamed or modified, DocC references should be updated.
…re the SDK (#3424) Fixes the Android CI workflow ### Motivation: The recently-added Android SDK workflow [fails](https://github.com/apple/swift-nio/actions/runs/18718487605/job/53384086329?pr=3418) (as mentioned at #3418 (comment)). The confusing error message is due to a post-install step that is needed to download and link the Android NDK into the Swift SDK's artifactbundle. This PR also adds a one-line fix to [Sources/NIOPerformanceTester/main.swift](main...swift-android-sdk:swift-nio:main#diff-de179adbbfacb89c9533f4efd21f7f641eedc0c8642d7d650cdfc9d9278a7a55) that gets it building for Android so the entire swift-nio package can be built. ### Modifications: Adds a post-install step to the SDK installation that is needed for the Swift SDK for Android. This is the same technique used by swiftlang/github-workflows#172, and is described as a necessary step in the [Android getting started guide](https://github.com/swiftlang/swift-org-website/blob/0dc655ce267e7b6bada2a2032cc7855c3b5e19d9/documentation/articles/swift-android-getting-started.md) ### Result: The "Android Swift SDK" CI check should now pass successfully. See an example at https://github.com/swift-android-sdk/swift-nio/actions/runs/18761057590/job/53525442382 ### Note: This PR will _not_ pass the Android check until it has been merged, because it relies on being able to down the the script https://raw.githubusercontent.com/apple/swift-nio/main/scripts/install_swift_sdk.sh from `apple/swift-nio/main`, which will not include the Android fix until the PR is merged. But once it is merged, the Android SDK CI should start passing.
Pursuant to #83, this PR adds support for building with the Swift SDK for Android, following the precedents set by the Swift SDK for Wasm and the Static Linux SDK.
Unlike #106, this PR doesn't cover testing, which would necessitate installing and configuring an Android emulator.